{% extends "base.html" %}

{% block title %}注册{% endblock %}

{% block content %}
<div class="auth-container">
    <div class="auth-card">
        <h2>用户注册</h2>
        
        {% if error %}
        <div class="error-message">{{ error }}</div>
        {% endif %}
        
        <form method="POST">
            <div class="form-group">
                <label>用户名：</label>
                <input type="text" name="username" required>
            </div>
            <div class="form-group">
                <label>密码：</label>
                <input type="password" name="password" required>
            </div>
            <div class="form-group">
                <label>确认密码：</label>
                <input type="password" name="confirm_password" required>
            </div>
            <button type="submit" class="btn">注册</button>
        </form>
        
        <p class="auth-link">
            已有账号？ <a href="{{ url_for('login') }}">立即登录</a>
        </p>
    </div>
</div>
{% endblock %}